<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Repetier-Firmware: src/ArduinoAVR/Repetier/motion.h Source File</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  <td id="projectlogo"><img alt="Logo" src="repetier-logo-trans128.png"/></td>
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">Repetier-Firmware
   &#160;<span id="projectnumber">0.91</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.6.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="pages.html"><span>Related&#160;Pages</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li><a href="annotated.html"><span>Data&#160;Structures</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>Globals</span></a></li>
    </ul>
  </div>
</div>
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
  initNavTree('motion_8h.html','');
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">src/ArduinoAVR/Repetier/motion.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="motion_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/*</span>
<a name="l00002"></a>00002 <span class="comment">    This file is part of Repetier-Firmware.</span>
<a name="l00003"></a>00003 <span class="comment"></span>
<a name="l00004"></a>00004 <span class="comment">    Repetier-Firmware is free software: you can redistribute it and/or modify</span>
<a name="l00005"></a>00005 <span class="comment">    it under the terms of the GNU General Public License as published by</span>
<a name="l00006"></a>00006 <span class="comment">    the Free Software Foundation, either version 3 of the License, or</span>
<a name="l00007"></a>00007 <span class="comment">    (at your option) any later version.</span>
<a name="l00008"></a>00008 <span class="comment"></span>
<a name="l00009"></a>00009 <span class="comment">    Repetier-Firmware is distributed in the hope that it will be useful,</span>
<a name="l00010"></a>00010 <span class="comment">    but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
<a name="l00011"></a>00011 <span class="comment">    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span>
<a name="l00012"></a>00012 <span class="comment">    GNU General Public License for more details.</span>
<a name="l00013"></a>00013 <span class="comment"></span>
<a name="l00014"></a>00014 <span class="comment">    You should have received a copy of the GNU General Public License</span>
<a name="l00015"></a>00015 <span class="comment">    along with Repetier-Firmware.  If not, see &lt;http://www.gnu.org/licenses/&gt;.</span>
<a name="l00016"></a>00016 <span class="comment"></span>
<a name="l00017"></a>00017 <span class="comment">    This firmware is a nearly complete rewrite of the sprinter firmware</span>
<a name="l00018"></a>00018 <span class="comment">    by kliment (https://github.com/kliment/Sprinter)</span>
<a name="l00019"></a>00019 <span class="comment">    which based on Tonokip RepRap firmware rewrite based off of Hydra-mmm firmware.</span>
<a name="l00020"></a>00020 <span class="comment">#</span>
<a name="l00021"></a>00021 <span class="comment">  Functions in this file are used to communicate using ascii or repetier protocol.</span>
<a name="l00022"></a>00022 <span class="comment">*/</span>
<a name="l00023"></a>00023 
<a name="l00024"></a>00024 <span class="preprocessor">#ifndef MOTION_H_INCLUDED</span>
<a name="l00025"></a>00025 <span class="preprocessor"></span><span class="preprocessor">#define MOTION_H_INCLUDED</span>
<a name="l00026"></a>00026 <span class="preprocessor"></span>
<a name="l00028"></a><a class="code" href="motion_8h.html#a6a2aad6af3e26a70043bb667d9fe6722">00028</a> <span class="preprocessor">#define FLAG_WARMUP 1</span>
<a name="l00029"></a><a class="code" href="motion_8h.html#a6d532b3a91829ce965b11bee7ce4a121">00029</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_NOMINAL 2</span>
<a name="l00030"></a><a class="code" href="motion_8h.html#ae80288e7929d2dd9a7a4aedcbbb53dbc">00030</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_DECELERATING 4</span>
<a name="l00031"></a><a class="code" href="motion_8h.html#a2c78abde6b572b9cce3ba10bd79b5c7b">00031</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_ACCELERATION_ENABLED 8</span>
<a name="l00032"></a><a class="code" href="motion_8h.html#a4928545b38f0d9f7c1cef343171db6b6">00032</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_CHECK_ENDSTOPS 16</span>
<a name="l00033"></a><a class="code" href="motion_8h.html#a1ce63ff7ba772791b6a64c15f80af9b9">00033</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_SKIP_ACCELERATING 32</span>
<a name="l00034"></a><a class="code" href="motion_8h.html#afc633f974340414dfcc3da9489f8a9c3">00034</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_SKIP_DEACCELERATING 64</span>
<a name="l00035"></a><a class="code" href="motion_8h.html#aafd724d9cac420e263072927b00d9a45">00035</a> <span class="preprocessor"></span><span class="preprocessor">#define FLAG_BLOCKED 128</span>
<a name="l00036"></a>00036 <span class="preprocessor"></span>
<a name="l00038"></a><a class="code" href="motion_8h.html#a5f7d3ac3ef6f32915b3893dd59c3ca9b">00038</a> <span class="preprocessor">#define FLAG_JOIN_STEPPARAMS_COMPUTED 1</span>
<a name="l00039"></a>00039 <span class="preprocessor"></span>
<a name="l00040"></a><a class="code" href="motion_8h.html#a59de958cd229719951c39ec47980612a">00040</a> <span class="preprocessor">#define FLAG_JOIN_END_FIXED 2</span>
<a name="l00041"></a>00041 <span class="preprocessor"></span>
<a name="l00042"></a><a class="code" href="motion_8h.html#afd2aa0f699051519425a93e6d2b3ea86">00042</a> <span class="preprocessor">#define FLAG_JOIN_START_FIXED 4</span>
<a name="l00043"></a>00043 <span class="preprocessor"></span>
<a name="l00044"></a><a class="code" href="motion_8h.html#ae3200ea7e0c130f7954f879bf2134652">00044</a> <span class="preprocessor">#define FLAG_JOIN_START_RETRACT 8</span>
<a name="l00045"></a>00045 <span class="preprocessor"></span>
<a name="l00046"></a><a class="code" href="motion_8h.html#a6bce9130720024781aa7d8b24b08d1fc">00046</a> <span class="preprocessor">#define FLAG_JOIN_END_RETRACT 16</span>
<a name="l00047"></a>00047 <span class="preprocessor"></span>
<a name="l00048"></a><a class="code" href="motion_8h.html#a6c722c1ac9bb7f554885dc6d746d1283">00048</a> <span class="preprocessor">#define FLAG_JOIN_NO_RETRACT 32</span>
<a name="l00049"></a>00049 <span class="preprocessor"></span>
<a name="l00050"></a><a class="code" href="motion_8h.html#a20fd0b9b6301f01d0127ab40b93ca860">00050</a> <span class="preprocessor">#define FLAG_JOIN_WAIT_EXTRUDER_UP 64</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span>
<a name="l00052"></a><a class="code" href="motion_8h.html#ac8e3ee431a59c64705f133d526eb435b">00052</a> <span class="preprocessor">#define FLAG_JOIN_WAIT_EXTRUDER_DOWN 128</span>
<a name="l00053"></a>00053 <span class="preprocessor"></span><span class="comment">// Printing related data</span>
<a name="l00054"></a>00054 <span class="preprocessor">#if NONLINEAR_SYSTEM</span>
<a name="l00055"></a>00055 <span class="preprocessor"></span><span class="comment">// Allow the delta cache to store segments for every line in line cache. Beware this gets big ... fast.</span>
<a name="l00056"></a>00056 <span class="comment">// MAX_DELTA_SEGMENTS_PER_LINE *</span>
<a name="l00057"></a>00057 <span class="preprocessor">#define DELTA_CACHE_SIZE (MAX_DELTA_SEGMENTS_PER_LINE * MOVE_CACHE_SIZE)</span>
<a name="l00058"></a>00058 <span class="preprocessor"></span>
<a name="l00059"></a>00059 <span class="keyword">class </span><a class="code" href="class_print_line.html">PrintLine</a>;
<a name="l00060"></a>00060 <span class="keyword">typedef</span> <span class="keyword">struct</span>
<a name="l00061"></a>00061 {
<a name="l00062"></a>00062     uint8_t <a class="code" href="class_print_line.html#a92abda0bec7c1c978fe96f87aad18067" title="Direction of movement. 1 = X+, 2 = Y+, 4= Z+, values can be combined.">dir</a>;                                                                        
<a name="l00063"></a>00063     uint16_t deltaSteps[3];                                 
<a name="l00064"></a>00064     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a9216eeee5a910d9b97ef7fc9c51486fb">checkEndstops</a>(<a class="code" href="class_print_line.html">PrintLine</a> *<a class="code" href="class_print_line.html#a272556ffc75dd36b17dba53b9e81de88" title="Current printing line.">cur</a>,<span class="keywordtype">bool</span> checkall);
<a name="l00065"></a>00065     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#aad67d2d7fdc415a10276ef11be6a4ebb">setXMoveFinished</a>()
<a name="l00066"></a>00066     {
<a name="l00067"></a>00067         dir&amp;=~16;
<a name="l00068"></a>00068     }
<a name="l00069"></a>00069     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ae9f3a1556eb7d20e66bede8747f6447b">setYMoveFinished</a>()
<a name="l00070"></a>00070     {
<a name="l00071"></a>00071         dir&amp;=~32;
<a name="l00072"></a>00072     }
<a name="l00073"></a>00073     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>()
<a name="l00074"></a>00074     {
<a name="l00075"></a>00075         dir&amp;=~64;
<a name="l00076"></a>00076     }
<a name="l00077"></a>00077     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a72e2663eddc20d0d43265837ee7c03bd">setXYMoveFinished</a>()
<a name="l00078"></a>00078     {
<a name="l00079"></a>00079         dir&amp;=~48;
<a name="l00080"></a>00080     }
<a name="l00081"></a>00081     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">isXPositiveMove</a>()
<a name="l00082"></a>00082     {
<a name="l00083"></a>00083         <span class="keywordflow">return</span> (dir &amp; 17)==17;
<a name="l00084"></a>00084     }
<a name="l00085"></a>00085     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aabc1316f4405ac616dbd4d5ece65fd66">isXNegativeMove</a>()
<a name="l00086"></a>00086     {
<a name="l00087"></a>00087         <span class="keywordflow">return</span> (dir &amp; 17)==16;
<a name="l00088"></a>00088     }
<a name="l00089"></a>00089     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">isYPositiveMove</a>()
<a name="l00090"></a>00090     {
<a name="l00091"></a>00091         <span class="keywordflow">return</span> (dir &amp; 34)==34;
<a name="l00092"></a>00092     }
<a name="l00093"></a>00093     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a393df21fe03ce39f5dce37753510e369">isYNegativeMove</a>()
<a name="l00094"></a>00094     {
<a name="l00095"></a>00095         <span class="keywordflow">return</span> (dir &amp; 34)==32;
<a name="l00096"></a>00096     }
<a name="l00097"></a>00097     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0bc2674212b458863e559f31692431c6">isZPositiveMove</a>()
<a name="l00098"></a>00098     {
<a name="l00099"></a>00099         <span class="keywordflow">return</span> (dir &amp; 68)==68;
<a name="l00100"></a>00100     }
<a name="l00101"></a>00101     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0730f709b8acdad51a60b2eee220fcdd">isZNegativeMove</a>()
<a name="l00102"></a>00102     {
<a name="l00103"></a>00103         <span class="keywordflow">return</span> (dir &amp; 68)==64;
<a name="l00104"></a>00104     }
<a name="l00105"></a>00105     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#af8fa116704ec13fe8fc574016d41769a">isEPositiveMove</a>()
<a name="l00106"></a>00106     {
<a name="l00107"></a>00107         <span class="keywordflow">return</span> (dir &amp; 136)==136;
<a name="l00108"></a>00108     }
<a name="l00109"></a>00109     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#adbe7df66129d7bfa99d9e2ceb7457c69">isENegativeMove</a>()
<a name="l00110"></a>00110     {
<a name="l00111"></a>00111         <span class="keywordflow">return</span> (dir &amp; 136)==128;
<a name="l00112"></a>00112     }
<a name="l00113"></a>00113     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae4ce3dd29cb20a699d90c9fb7cc87f28">isXMove</a>()
<a name="l00114"></a>00114     {
<a name="l00115"></a>00115         <span class="keywordflow">return</span> (dir &amp; 16);
<a name="l00116"></a>00116     }
<a name="l00117"></a>00117     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae6f2dadb0a57fe75ae2b49befd8a45eb">isYMove</a>()
<a name="l00118"></a>00118     {
<a name="l00119"></a>00119         <span class="keywordflow">return</span> (dir &amp; 32);
<a name="l00120"></a>00120     }
<a name="l00121"></a>00121     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aa38c32d9bee47e266dd198b5d1ca1102">isXOrYMove</a>()
<a name="l00122"></a>00122     {
<a name="l00123"></a>00123         <span class="keywordflow">return</span> dir &amp; 48;
<a name="l00124"></a>00124     }
<a name="l00125"></a>00125     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a34ddbda7b07722da0e1b93001d549a4a">isZMove</a>()
<a name="l00126"></a>00126     {
<a name="l00127"></a>00127         <span class="keywordflow">return</span> (dir &amp; 64);
<a name="l00128"></a>00128     }
<a name="l00129"></a>00129     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a303bf057849da5f62827cfdbc2ad6326">isEMove</a>()
<a name="l00130"></a>00130     {
<a name="l00131"></a>00131         <span class="keywordflow">return</span> (dir &amp; 128);
<a name="l00132"></a>00132     }
<a name="l00133"></a>00133     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a4833a7f801c417b392ecb5504d0a1cef">isEOnlyMove</a>()
<a name="l00134"></a>00134     {
<a name="l00135"></a>00135         <span class="keywordflow">return</span> (dir &amp; 240)==128;
<a name="l00136"></a>00136     }
<a name="l00137"></a>00137     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a589c1fda795565f72c8872cb8a1a389b">isNoMove</a>()
<a name="l00138"></a>00138     {
<a name="l00139"></a>00139         <span class="keywordflow">return</span> (dir &amp; 240)==0;
<a name="l00140"></a>00140     }
<a name="l00141"></a>00141     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a04d6b0f87d5f38101802d9ebf704e1fd">isXYZMove</a>()
<a name="l00142"></a>00142     {
<a name="l00143"></a>00143         <span class="keywordflow">return</span> dir &amp; 112;
<a name="l00144"></a>00144     }
<a name="l00145"></a>00145     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0d92e184b7728d79f2d932db5bde6c8d">isMoveOfAxis</a>(uint8_t axis)
<a name="l00146"></a>00146     {
<a name="l00147"></a>00147         <span class="keywordflow">return</span> (dir &amp; (16&lt;&lt;axis));
<a name="l00148"></a>00148     }
<a name="l00149"></a>00149     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a6cc01d8dcc37c4fa8fdaa67b3cbaa9aa">setMoveOfAxis</a>(uint8_t axis)
<a name="l00150"></a>00150     {
<a name="l00151"></a>00151         dir |= 16&lt;&lt;axis;
<a name="l00152"></a>00152     }
<a name="l00153"></a>00153     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a58c08ce30a6b0df067300649e37fdbba">setPositiveDirectionForAxis</a>(uint8_t axis)
<a name="l00154"></a>00154     {
<a name="l00155"></a>00155         dir |= 1&lt;&lt;axis;
<a name="l00156"></a>00156     }
<a name="l00157"></a>00157 } DeltaSegment;
<a name="l00158"></a>00158 <span class="keyword">extern</span> uint8_t lastMoveID;
<a name="l00159"></a>00159 <span class="preprocessor">#endif</span>
<a name="l00160"></a>00160 <span class="preprocessor"></span><span class="keyword">class </span><a class="code" href="class_u_i_display.html">UIDisplay</a>;
<a name="l00161"></a><a class="code" href="class_print_line.html">00161</a> <span class="keyword">class </span><a class="code" href="class_print_line.html">PrintLine</a>   <span class="comment">// RAM usage: 24*4+15 = 113 Byte</span>
<a name="l00162"></a>00162 {
<a name="l00163"></a><a class="code" href="class_print_line.html#a9100ab40407fd382a882168b2001f3a3">00163</a>     <span class="keyword">friend</span> <span class="keyword">class </span><a class="code" href="class_u_i_display.html">UIDisplay</a>;
<a name="l00164"></a>00164 <span class="preprocessor">#if CPU_ARCH==ARCH_ARM</span>
<a name="l00165"></a><a class="code" href="class_print_line.html#aef1b1ee43dd2cf1e9322f6c2c946c145">00165</a> <span class="preprocessor"></span>    <span class="keyword">static</span> <span class="keyword">volatile</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aef1b1ee43dd2cf1e9322f6c2c946c145">nlFlag</a>;
<a name="l00166"></a>00166 <span class="preprocessor">#endif</span>
<a name="l00167"></a><a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098">00167</a> <span class="preprocessor"></span>    <span class="keyword">static</span> uint8_t <a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a>; <span class="comment">// Position for executing line movement</span>
<a name="l00168"></a><a class="code" href="class_print_line.html#a3fc3b5578c9735d1af55e62111fb9f03">00168</a>     <span class="keyword">static</span> <a class="code" href="class_print_line.html">PrintLine</a> <a class="code" href="class_print_line.html#a3fc3b5578c9735d1af55e62111fb9f03" title="Cache for print moves.">lines</a>[];
<a name="l00169"></a><a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1">00169</a>     <span class="keyword">static</span> uint8_t <a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a>; <span class="comment">// Position where we write the next cached line move</span>
<a name="l00170"></a><a class="code" href="class_print_line.html#a07bea818f3a912947549699bfdef6a73">00170</a>     uint8_t <a class="code" href="class_print_line.html#a07bea818f3a912947549699bfdef6a73">primaryAxis</a>;
<a name="l00171"></a><a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">00171</a>     <span class="keyword">volatile</span> uint8_t <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a>;
<a name="l00172"></a><a class="code" href="class_print_line.html#a606788ac5a4df6a49dac455473a1bb73">00172</a>     <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a606788ac5a4df6a49dac455473a1bb73">timeInTicks</a>;
<a name="l00173"></a><a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">00173</a>     uint8_t <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a>;
<a name="l00174"></a><a class="code" href="class_print_line.html#aa5bb967d7e0b7e9ec796f65835ee9d6e">00174</a>     uint8_t <a class="code" href="class_print_line.html#aa5bb967d7e0b7e9ec796f65835ee9d6e" title="4 = disabled, 1 = halfstep, 2 = fulstep">halfStep</a>;                  
<a name="l00175"></a><a class="code" href="class_print_line.html#a92abda0bec7c1c978fe96f87aad18067">00175</a>     uint8_t <a class="code" href="class_print_line.html#a92abda0bec7c1c978fe96f87aad18067" title="Direction of movement. 1 = X+, 2 = Y+, 4= Z+, values can be combined.">dir</a>;                       
<a name="l00176"></a><a class="code" href="class_print_line.html#acddb9b941799c58b09b9ba557a550ba9">00176</a>     <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#acddb9b941799c58b09b9ba557a550ba9" title="Steps we want to move.">delta</a>[4];                  
<a name="l00177"></a><a class="code" href="class_print_line.html#a3c6de671d3ddb66984484dc28d461238">00177</a>     <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a3c6de671d3ddb66984484dc28d461238" title="Error calculation for Bresenham algorithm.">error</a>[4];                  
<a name="l00178"></a><a class="code" href="class_print_line.html#aa0076a8395b89235fd3411ef7f96bc99">00178</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#aa0076a8395b89235fd3411ef7f96bc99" title="Speed in x direction at fullInterval in mm/s.">speedX</a>;                   
<a name="l00179"></a><a class="code" href="class_print_line.html#a742025f2597ee001a8c61abea1070f0b">00179</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a742025f2597ee001a8c61abea1070f0b" title="Speed in y direction at fullInterval in mm/s.">speedY</a>;                   
<a name="l00180"></a><a class="code" href="class_print_line.html#aec11ac0ec6a0c95d25828f3a5d38f8d3">00180</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#aec11ac0ec6a0c95d25828f3a5d38f8d3" title="Speed in z direction at fullInterval in mm/s.">speedZ</a>;                   
<a name="l00181"></a><a class="code" href="class_print_line.html#ab246a6f56412557306bd8525bec07765">00181</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#ab246a6f56412557306bd8525bec07765" title="Speed in E direction at fullInterval in mm/s.">speedE</a>;                   
<a name="l00182"></a><a class="code" href="class_print_line.html#af2dda87e11a7a84a9ae816f22066d84f">00182</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#af2dda87e11a7a84a9ae816f22066d84f" title="Desired speed mm/s.">fullSpeed</a>;                
<a name="l00183"></a><a class="code" href="class_print_line.html#a0009fafd27bac173d490371b1c325202">00183</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a0009fafd27bac173d490371b1c325202" title="1.0/fullSpeed for fatser computation">invFullSpeed</a>;             
<a name="l00184"></a><a class="code" href="class_print_line.html#ab31effe773625c44619f5de770c2596f">00184</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#ab31effe773625c44619f5de770c2596f" title="Real 2.0*distanceÜacceleration mm²/s²">accelerationDistance2</a>;             
<a name="l00185"></a><a class="code" href="class_print_line.html#a2f126b0724528257a5906804414175c3">00185</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a2f126b0724528257a5906804414175c3" title="Max. junction speed between this and next segment.">maxJunctionSpeed</a>;         
<a name="l00186"></a><a class="code" href="class_print_line.html#a0976722c9e2db986c298e6de2f0a966c">00186</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a0976722c9e2db986c298e6de2f0a966c" title="Staring speed in mm/s.">startSpeed</a>;               
<a name="l00187"></a><a class="code" href="class_print_line.html#adefb2a3853aa8166b3fb2940d7a78622">00187</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#adefb2a3853aa8166b3fb2940d7a78622" title="Exit speed in mm/s.">endSpeed</a>;                 
<a name="l00188"></a><a class="code" href="class_print_line.html#abdc3d6a5585f0a78d67b3b51fb38e618">00188</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#abdc3d6a5585f0a78d67b3b51fb38e618">minSpeed</a>;
<a name="l00189"></a><a class="code" href="class_print_line.html#a06f14a9abd47b91465f895d5259cdc1b">00189</a>     <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a06f14a9abd47b91465f895d5259cdc1b">distance</a>;
<a name="l00190"></a>00190 <span class="preprocessor">#if NONLINEAR_SYSTEM</span>
<a name="l00191"></a>00191 <span class="preprocessor"></span>    uint8_t numDeltaSegments;           
<a name="l00192"></a>00192     uint8_t moveID;                                     
<a name="l00193"></a>00193     <span class="keywordtype">long</span> numPrimaryStepPerSegment;      
<a name="l00194"></a>00194     DeltaSegment segments[<a class="code" href="_configuration_8h.html#a147f62b0bcb70fda0ace1984698b6176" title="Number of delta moves in each line. Moves that exceed this figure will be split into multiple lines...">MAX_DELTA_SEGMENTS_PER_LINE</a>];
<a name="l00195"></a>00195 <span class="preprocessor">#endif</span>
<a name="l00196"></a><a class="code" href="class_print_line.html#a0ca91033188e4f8b4b51caac393d8fe8">00196</a> <span class="preprocessor"></span>    <a class="code" href="_h_a_l_8h.html#a91c2da9328232ca544377f4be938288d">ticks_t</a> <a class="code" href="class_print_line.html#a0ca91033188e4f8b4b51caac393d8fe8" title="interval at full speed in ticks/step.">fullInterval</a>;     
<a name="l00197"></a><a class="code" href="class_print_line.html#afd69a1548f5674700c6ba5fd6a55914c">00197</a>     <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="class_print_line.html#afd69a1548f5674700c6ba5fd6a55914c" title="How much steps does it take, to reach the plateau.">accelSteps</a>;        
<a name="l00198"></a><a class="code" href="class_print_line.html#a9ff32dda312a8ba553474117042721d4">00198</a>     <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="class_print_line.html#a9ff32dda312a8ba553474117042721d4" title="How much steps does it take, to reach the end speed.">decelSteps</a>;        
<a name="l00199"></a><a class="code" href="class_print_line.html#ab47d96a0400955944bcb72926bd98841">00199</a>     <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#ab47d96a0400955944bcb72926bd98841" title="Acceleration along primary axis.">accelerationPrim</a>; 
<a name="l00200"></a><a class="code" href="class_print_line.html#a10fa1d8f9dc6cdc51e12bbd86b964b01">00200</a>     <span class="keywordtype">unsigned</span> <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a10fa1d8f9dc6cdc51e12bbd86b964b01" title="accelerationPrim*262144/F_CPU">fAcceleration</a>;    
<a name="l00201"></a><a class="code" href="class_print_line.html#a75a36d8192c1f543a9998466dbcdc8ce">00201</a>     <a class="code" href="_h_a_l_8h.html#a14a0666abcf3bb67c7ff400b4a450467">speed_t</a> <a class="code" href="class_print_line.html#a75a36d8192c1f543a9998466dbcdc8ce" title="Maximum reached speed in steps/s.">vMax</a>;              
<a name="l00202"></a><a class="code" href="class_print_line.html#abe84967de3e7dd73e62a911c58dda57b">00202</a>     <a class="code" href="_h_a_l_8h.html#a14a0666abcf3bb67c7ff400b4a450467">speed_t</a> <a class="code" href="class_print_line.html#abe84967de3e7dd73e62a911c58dda57b" title="Starting speed in steps/s.">vStart</a>;            
<a name="l00203"></a><a class="code" href="class_print_line.html#abd65545ed253eff8f6e3ca4b888e5bf2">00203</a>     <a class="code" href="_h_a_l_8h.html#a14a0666abcf3bb67c7ff400b4a450467">speed_t</a> <a class="code" href="class_print_line.html#abd65545ed253eff8f6e3ca4b888e5bf2" title="End speed in steps/s.">vEnd</a>;              
<a name="l00204"></a>00204 <span class="preprocessor">#ifdef USE_ADVANCE</span>
<a name="l00205"></a>00205 <span class="preprocessor"></span><span class="preprocessor">#ifdef ENABLE_QUADRATIC_ADVANCE</span>
<a name="l00206"></a>00206 <span class="preprocessor"></span>    <span class="keywordtype">long</span> advanceRate;               
<a name="l00207"></a>00207     <span class="keywordtype">long</span> advanceFull;               
<a name="l00208"></a>00208     <span class="keywordtype">long</span> advanceStart;
<a name="l00209"></a>00209     <span class="keywordtype">long</span> advanceEnd;
<a name="l00210"></a>00210 <span class="preprocessor">#endif</span>
<a name="l00211"></a>00211 <span class="preprocessor"></span>    <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> advanceL;         
<a name="l00212"></a>00212 <span class="preprocessor">#endif</span>
<a name="l00213"></a>00213 <span class="preprocessor"></span><span class="preprocessor">#ifdef DEBUG_STEPCOUNT</span>
<a name="l00214"></a>00214 <span class="preprocessor"></span>    <span class="keywordtype">long</span> totalStepsRemaining;
<a name="l00215"></a>00215 <span class="preprocessor">#endif</span>
<a name="l00216"></a>00216 <span class="preprocessor"></span><span class="keyword">public</span>:
<a name="l00217"></a><a class="code" href="class_print_line.html#a5a87d2c42cc21fa0022be9e1450a6877">00217</a>     <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a5a87d2c42cc21fa0022be9e1450a6877" title="Remaining steps, until move is finished.">stepsRemaining</a>;            
<a name="l00218"></a><a class="code" href="class_print_line.html#a272556ffc75dd36b17dba53b9e81de88">00218</a>     <span class="keyword">static</span> <a class="code" href="class_print_line.html">PrintLine</a> *<a class="code" href="class_print_line.html#a272556ffc75dd36b17dba53b9e81de88" title="Current printing line.">cur</a>;
<a name="l00219"></a><a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef">00219</a>     <span class="keyword">static</span> <span class="keyword">volatile</span> uint8_t <a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef" title="Number of lines cached 0 = nothing to do.">linesCount</a>; <span class="comment">// Number of lines cached 0 = nothing to do</span>
<a name="l00220"></a><a class="code" href="class_print_line.html#a1d2cbe11872ed43ecf5e7698c6a3753c">00220</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a1d2cbe11872ed43ecf5e7698c6a3753c">areParameterUpToDate</a>()
<a name="l00221"></a>00221     {
<a name="l00222"></a>00222         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp; <a class="code" href="motion_8h.html#a5f7d3ac3ef6f32915b3893dd59c3ca9b">FLAG_JOIN_STEPPARAMS_COMPUTED</a>;
<a name="l00223"></a>00223     }
<a name="l00224"></a><a class="code" href="class_print_line.html#a133e03a70ead89a6530cfb29e84c4b23">00224</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a133e03a70ead89a6530cfb29e84c4b23">invalidateParameter</a>()
<a name="l00225"></a>00225     {
<a name="l00226"></a>00226         <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp;= ~<a class="code" href="motion_8h.html#a5f7d3ac3ef6f32915b3893dd59c3ca9b">FLAG_JOIN_STEPPARAMS_COMPUTED</a>;
<a name="l00227"></a>00227     }
<a name="l00228"></a><a class="code" href="class_print_line.html#a8078bbbf77346f72ab52e95e7c5c94b6">00228</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a8078bbbf77346f72ab52e95e7c5c94b6">setParameterUpToDate</a>()
<a name="l00229"></a>00229     {
<a name="l00230"></a>00230         <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> |= <a class="code" href="motion_8h.html#a5f7d3ac3ef6f32915b3893dd59c3ca9b">FLAG_JOIN_STEPPARAMS_COMPUTED</a>;
<a name="l00231"></a>00231     }
<a name="l00232"></a><a class="code" href="class_print_line.html#ae9ca9bfdc8d855bf8c449f1db91c7baf">00232</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae9ca9bfdc8d855bf8c449f1db91c7baf">isStartSpeedFixed</a>()
<a name="l00233"></a>00233     {
<a name="l00234"></a>00234         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp; <a class="code" href="motion_8h.html#afd2aa0f699051519425a93e6d2b3ea86">FLAG_JOIN_START_FIXED</a>;
<a name="l00235"></a>00235     }
<a name="l00236"></a><a class="code" href="class_print_line.html#ab18ab9269486043849d90b27c8d0e59e">00236</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ab18ab9269486043849d90b27c8d0e59e">setStartSpeedFixed</a>(<span class="keywordtype">bool</span> newState)
<a name="l00237"></a>00237     {
<a name="l00238"></a>00238         <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> = (newState ? <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> | <a class="code" href="motion_8h.html#afd2aa0f699051519425a93e6d2b3ea86">FLAG_JOIN_START_FIXED</a> : <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp; ~<a class="code" href="motion_8h.html#afd2aa0f699051519425a93e6d2b3ea86">FLAG_JOIN_START_FIXED</a>);
<a name="l00239"></a>00239     }
<a name="l00240"></a><a class="code" href="class_print_line.html#a0197c6efb9afd7d6ab13b297f2df73dc">00240</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a0197c6efb9afd7d6ab13b297f2df73dc">fixStartAndEndSpeed</a>()
<a name="l00241"></a>00241     {
<a name="l00242"></a>00242         <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> |= <a class="code" href="motion_8h.html#a59de958cd229719951c39ec47980612a">FLAG_JOIN_END_FIXED</a> | <a class="code" href="motion_8h.html#afd2aa0f699051519425a93e6d2b3ea86">FLAG_JOIN_START_FIXED</a>;
<a name="l00243"></a>00243     }
<a name="l00244"></a><a class="code" href="class_print_line.html#a935def6124c31e1b948fc3f659937116">00244</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a935def6124c31e1b948fc3f659937116">isEndSpeedFixed</a>()
<a name="l00245"></a>00245     {
<a name="l00246"></a>00246         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp; <a class="code" href="motion_8h.html#a59de958cd229719951c39ec47980612a">FLAG_JOIN_END_FIXED</a>;
<a name="l00247"></a>00247     }
<a name="l00248"></a><a class="code" href="class_print_line.html#a4ac3e198b5ae2f2c2c02707b5d79fadb">00248</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a4ac3e198b5ae2f2c2c02707b5d79fadb">setEndSpeedFixed</a>(<span class="keywordtype">bool</span> newState)
<a name="l00249"></a>00249     {
<a name="l00250"></a>00250         <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> = (newState ? <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> | <a class="code" href="motion_8h.html#a59de958cd229719951c39ec47980612a">FLAG_JOIN_END_FIXED</a> : <a class="code" href="class_print_line.html#a929492d0ab9b4ea4338f81381d08e63e">joinFlags</a> &amp; ~<a class="code" href="motion_8h.html#a59de958cd229719951c39ec47980612a">FLAG_JOIN_END_FIXED</a>);
<a name="l00251"></a>00251     }
<a name="l00252"></a><a class="code" href="class_print_line.html#aa1b213782c45e8e05c34360768f32131">00252</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aa1b213782c45e8e05c34360768f32131">isWarmUp</a>()
<a name="l00253"></a>00253     {
<a name="l00254"></a>00254         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp; <a class="code" href="motion_8h.html#a6a2aad6af3e26a70043bb667d9fe6722">FLAG_WARMUP</a>;
<a name="l00255"></a>00255     }
<a name="l00256"></a><a class="code" href="class_print_line.html#aba0df0f31d8acaa1dd3a8618b2e178e8">00256</a>     <span class="keyword">inline</span> uint8_t <a class="code" href="class_print_line.html#aba0df0f31d8acaa1dd3a8618b2e178e8">getWaitForXLinesFilled</a>()
<a name="l00257"></a>00257     {
<a name="l00258"></a>00258         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a07bea818f3a912947549699bfdef6a73">primaryAxis</a>;
<a name="l00259"></a>00259     }
<a name="l00260"></a><a class="code" href="class_print_line.html#abd0ecb7d97383e5cfc4cb495818c389e">00260</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#abd0ecb7d97383e5cfc4cb495818c389e">setWaitForXLinesFilled</a>(uint8_t b)
<a name="l00261"></a>00261     {
<a name="l00262"></a>00262         <a class="code" href="class_print_line.html#a07bea818f3a912947549699bfdef6a73">primaryAxis</a> = b;
<a name="l00263"></a>00263     }
<a name="l00264"></a><a class="code" href="class_print_line.html#a7a4dba3ace1ac871133b0f12839e6f4f">00264</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a7a4dba3ace1ac871133b0f12839e6f4f">isExtruderForwardMove</a>()
<a name="l00265"></a>00265     {
<a name="l00266"></a>00266         <span class="keywordflow">return</span> (dir &amp; 136)==136;
<a name="l00267"></a>00267     }
<a name="l00268"></a><a class="code" href="class_print_line.html#a7e07c2af0cfe7618067f785518e9e64b">00268</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a7e07c2af0cfe7618067f785518e9e64b">block</a>()
<a name="l00269"></a>00269     {
<a name="l00270"></a>00270         <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> |= <a class="code" href="motion_8h.html#aafd724d9cac420e263072927b00d9a45">FLAG_BLOCKED</a>;
<a name="l00271"></a>00271     }
<a name="l00272"></a><a class="code" href="class_print_line.html#a009e9504e5d9ca912a7567892e0e60bf">00272</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a009e9504e5d9ca912a7567892e0e60bf">unblock</a>()
<a name="l00273"></a>00273     {
<a name="l00274"></a>00274         <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp;= ~<a class="code" href="motion_8h.html#aafd724d9cac420e263072927b00d9a45">FLAG_BLOCKED</a>;
<a name="l00275"></a>00275     }
<a name="l00276"></a><a class="code" href="class_print_line.html#ae6ec007d68382eb124ed25bc90ae9c17">00276</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae6ec007d68382eb124ed25bc90ae9c17">isBlocked</a>()
<a name="l00277"></a>00277     {
<a name="l00278"></a>00278         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp; <a class="code" href="motion_8h.html#aafd724d9cac420e263072927b00d9a45">FLAG_BLOCKED</a>;
<a name="l00279"></a>00279     }
<a name="l00280"></a><a class="code" href="class_print_line.html#a231c85e6f3815511831cb67567d82c95">00280</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a231c85e6f3815511831cb67567d82c95">isCheckEndstops</a>()
<a name="l00281"></a>00281     {
<a name="l00282"></a>00282         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp; <a class="code" href="motion_8h.html#a4928545b38f0d9f7c1cef343171db6b6">FLAG_CHECK_ENDSTOPS</a>;
<a name="l00283"></a>00283     }
<a name="l00284"></a><a class="code" href="class_print_line.html#a581476729a31739e3faa03a9431e4a05">00284</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a581476729a31739e3faa03a9431e4a05">isNominalMove</a>()
<a name="l00285"></a>00285     {
<a name="l00286"></a>00286         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp; <a class="code" href="motion_8h.html#a6d532b3a91829ce965b11bee7ce4a121">FLAG_NOMINAL</a>;
<a name="l00287"></a>00287     }
<a name="l00288"></a><a class="code" href="class_print_line.html#acac9d9744a18dfb65430380ff098ab67">00288</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#acac9d9744a18dfb65430380ff098ab67">setNominalMove</a>()
<a name="l00289"></a>00289     {
<a name="l00290"></a>00290         <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> |= <a class="code" href="motion_8h.html#a6d532b3a91829ce965b11bee7ce4a121">FLAG_NOMINAL</a>;
<a name="l00291"></a>00291     }
<a name="l00292"></a><a class="code" href="class_print_line.html#a9216eeee5a910d9b97ef7fc9c51486fb">00292</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a9216eeee5a910d9b97ef7fc9c51486fb">checkEndstops</a>()
<a name="l00293"></a>00293     {
<a name="l00294"></a>00294         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a231c85e6f3815511831cb67567d82c95">isCheckEndstops</a>())
<a name="l00295"></a>00295         {
<a name="l00296"></a>00296             <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#aabc1316f4405ac616dbd4d5ece65fd66">isXNegativeMove</a>() &amp;&amp; <a class="code" href="class_printer.html#ae89c73fef56e4aa977ea25bc0897f3c1">Printer::isXMinEndstopHit</a>())
<a name="l00297"></a>00297                 <a class="code" href="class_print_line.html#aad67d2d7fdc415a10276ef11be6a4ebb">setXMoveFinished</a>();
<a name="l00298"></a>00298             <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a393df21fe03ce39f5dce37753510e369">isYNegativeMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a38710b6865be3ab1f3337a7ad5a8e731">Printer::isYMinEndstopHit</a>())
<a name="l00299"></a>00299                 <a class="code" href="class_print_line.html#ae9f3a1556eb7d20e66bede8747f6447b">setYMoveFinished</a>();
<a name="l00300"></a>00300             <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">isXPositiveMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a734216941d078fe2768d01a1b2d9bc96">Printer::isXMaxEndstopHit</a>())
<a name="l00301"></a>00301                 <a class="code" href="class_print_line.html#aad67d2d7fdc415a10276ef11be6a4ebb">setXMoveFinished</a>();
<a name="l00302"></a>00302             <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">isYPositiveMove</a>() &amp;&amp; <a class="code" href="class_printer.html#ab51acb1c381041a571aeb61b48eff647">Printer::isYMaxEndstopHit</a>())
<a name="l00303"></a>00303                 <a class="code" href="class_print_line.html#ae9f3a1556eb7d20e66bede8747f6447b">setYMoveFinished</a>();
<a name="l00304"></a>00304         }
<a name="l00305"></a>00305 <span class="preprocessor">#if FEATURE_Z_PROBE</span>
<a name="l00306"></a>00306 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(<a class="code" href="class_printer.html#a11aa8b6ec20b27e96df39008588f4c85">Printer::isZProbingActive</a>() &amp;&amp; <a class="code" href="class_print_line.html#a0730f709b8acdad51a60b2eee220fcdd">isZNegativeMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a95d96e7390210e4d7579b15015f134fa">Printer::isZProbeHit</a>())
<a name="l00307"></a>00307         {
<a name="l00308"></a>00308             <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>();
<a name="l00309"></a>00309             Printer::stepsRemainingAtZHit = <a class="code" href="class_print_line.html#a5a87d2c42cc21fa0022be9e1450a6877" title="Remaining steps, until move is finished.">stepsRemaining</a>;
<a name="l00310"></a>00310         }
<a name="l00311"></a>00311         <span class="keywordflow">else</span>
<a name="l00312"></a>00312 <span class="preprocessor">#endif</span>
<a name="l00313"></a>00313 <span class="preprocessor"></span>            <span class="comment">// Test Z-Axis every step if necessary, otherwise it could easyly ruin your printer!</span>
<a name="l00314"></a>00314             <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a0730f709b8acdad51a60b2eee220fcdd">isZNegativeMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a0919e11a9fc92a38cdb12cec80a6e5de">Printer::isZMinEndstopHit</a>())
<a name="l00315"></a>00315                 <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>();
<a name="l00316"></a>00316         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a0bc2674212b458863e559f31692431c6">isZPositiveMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a59371201b3638eff79eae1aed30b93b3">Printer::isZMaxEndstopHit</a>())
<a name="l00317"></a>00317         {
<a name="l00318"></a>00318 <span class="preprocessor">#if MAX_HARDWARE_ENDSTOP_Z</span>
<a name="l00319"></a>00319 <span class="preprocessor"></span>            Printer::stepsRemainingAtZHit = <a class="code" href="class_print_line.html#a5a87d2c42cc21fa0022be9e1450a6877" title="Remaining steps, until move is finished.">stepsRemaining</a>;
<a name="l00320"></a>00320 <span class="preprocessor">#endif</span>
<a name="l00321"></a>00321 <span class="preprocessor"></span>            <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>();
<a name="l00322"></a>00322         }
<a name="l00323"></a>00323         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a0bc2674212b458863e559f31692431c6">isZPositiveMove</a>() &amp;&amp; <a class="code" href="class_printer.html#a59371201b3638eff79eae1aed30b93b3">Printer::isZMaxEndstopHit</a>())
<a name="l00324"></a>00324             <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>();
<a name="l00325"></a>00325     }
<a name="l00326"></a><a class="code" href="class_print_line.html#aad67d2d7fdc415a10276ef11be6a4ebb">00326</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#aad67d2d7fdc415a10276ef11be6a4ebb">setXMoveFinished</a>()
<a name="l00327"></a>00327     {
<a name="l00328"></a>00328 <span class="preprocessor">#if DRIVE_SYSTEM==0 || NONLINEAR_SYSTEM</span>
<a name="l00329"></a>00329 <span class="preprocessor"></span>        dir&amp;=~16;
<a name="l00330"></a>00330 <span class="preprocessor">#else</span>
<a name="l00331"></a>00331 <span class="preprocessor"></span>        dir&amp;=~48;
<a name="l00332"></a>00332 <span class="preprocessor">#endif</span>
<a name="l00333"></a>00333 <span class="preprocessor"></span>    }
<a name="l00334"></a><a class="code" href="class_print_line.html#ae9f3a1556eb7d20e66bede8747f6447b">00334</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ae9f3a1556eb7d20e66bede8747f6447b">setYMoveFinished</a>()
<a name="l00335"></a>00335     {
<a name="l00336"></a>00336 <span class="preprocessor">#if DRIVE_SYSTEM==0 || NONLINEAR_SYSTEM</span>
<a name="l00337"></a>00337 <span class="preprocessor"></span>        dir&amp;=~32;
<a name="l00338"></a>00338 <span class="preprocessor">#else</span>
<a name="l00339"></a>00339 <span class="preprocessor"></span>        dir&amp;=~48;
<a name="l00340"></a>00340 <span class="preprocessor">#endif</span>
<a name="l00341"></a>00341 <span class="preprocessor"></span>    }
<a name="l00342"></a><a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">00342</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a5c2a9f33763e1c2c7f526227ad3d03fa">setZMoveFinished</a>()
<a name="l00343"></a>00343     {
<a name="l00344"></a>00344         dir&amp;=~64;
<a name="l00345"></a>00345     }
<a name="l00346"></a><a class="code" href="class_print_line.html#a72e2663eddc20d0d43265837ee7c03bd">00346</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a72e2663eddc20d0d43265837ee7c03bd">setXYMoveFinished</a>()
<a name="l00347"></a>00347     {
<a name="l00348"></a>00348         dir&amp;=~48;
<a name="l00349"></a>00349     }
<a name="l00350"></a><a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">00350</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">isXPositiveMove</a>()
<a name="l00351"></a>00351     {
<a name="l00352"></a>00352         <span class="keywordflow">return</span> (dir &amp; 17)==17;
<a name="l00353"></a>00353     }
<a name="l00354"></a><a class="code" href="class_print_line.html#aabc1316f4405ac616dbd4d5ece65fd66">00354</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aabc1316f4405ac616dbd4d5ece65fd66">isXNegativeMove</a>()
<a name="l00355"></a>00355     {
<a name="l00356"></a>00356         <span class="keywordflow">return</span> (dir &amp; 17)==16;
<a name="l00357"></a>00357     }
<a name="l00358"></a><a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">00358</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">isYPositiveMove</a>()
<a name="l00359"></a>00359     {
<a name="l00360"></a>00360         <span class="keywordflow">return</span> (dir &amp; 34)==34;
<a name="l00361"></a>00361     }
<a name="l00362"></a><a class="code" href="class_print_line.html#a393df21fe03ce39f5dce37753510e369">00362</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a393df21fe03ce39f5dce37753510e369">isYNegativeMove</a>()
<a name="l00363"></a>00363     {
<a name="l00364"></a>00364         <span class="keywordflow">return</span> (dir &amp; 34)==32;
<a name="l00365"></a>00365     }
<a name="l00366"></a><a class="code" href="class_print_line.html#a0bc2674212b458863e559f31692431c6">00366</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0bc2674212b458863e559f31692431c6">isZPositiveMove</a>()
<a name="l00367"></a>00367     {
<a name="l00368"></a>00368         <span class="keywordflow">return</span> (dir &amp; 68)==68;
<a name="l00369"></a>00369     }
<a name="l00370"></a><a class="code" href="class_print_line.html#a0730f709b8acdad51a60b2eee220fcdd">00370</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0730f709b8acdad51a60b2eee220fcdd">isZNegativeMove</a>()
<a name="l00371"></a>00371     {
<a name="l00372"></a>00372         <span class="keywordflow">return</span> (dir &amp; 68)==64;
<a name="l00373"></a>00373     }
<a name="l00374"></a><a class="code" href="class_print_line.html#af8fa116704ec13fe8fc574016d41769a">00374</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#af8fa116704ec13fe8fc574016d41769a">isEPositiveMove</a>()
<a name="l00375"></a>00375     {
<a name="l00376"></a>00376         <span class="keywordflow">return</span> (dir &amp; 136)==136;
<a name="l00377"></a>00377     }
<a name="l00378"></a><a class="code" href="class_print_line.html#adbe7df66129d7bfa99d9e2ceb7457c69">00378</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#adbe7df66129d7bfa99d9e2ceb7457c69">isENegativeMove</a>()
<a name="l00379"></a>00379     {
<a name="l00380"></a>00380         <span class="keywordflow">return</span> (dir &amp; 136)==128;
<a name="l00381"></a>00381     }
<a name="l00382"></a><a class="code" href="class_print_line.html#ae4ce3dd29cb20a699d90c9fb7cc87f28">00382</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae4ce3dd29cb20a699d90c9fb7cc87f28">isXMove</a>()
<a name="l00383"></a>00383     {
<a name="l00384"></a>00384         <span class="keywordflow">return</span> (dir &amp; 16);
<a name="l00385"></a>00385     }
<a name="l00386"></a><a class="code" href="class_print_line.html#ae6f2dadb0a57fe75ae2b49befd8a45eb">00386</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ae6f2dadb0a57fe75ae2b49befd8a45eb">isYMove</a>()
<a name="l00387"></a>00387     {
<a name="l00388"></a>00388         <span class="keywordflow">return</span> (dir &amp; 32);
<a name="l00389"></a>00389     }
<a name="l00390"></a><a class="code" href="class_print_line.html#aa38c32d9bee47e266dd198b5d1ca1102">00390</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#aa38c32d9bee47e266dd198b5d1ca1102">isXOrYMove</a>()
<a name="l00391"></a>00391     {
<a name="l00392"></a>00392         <span class="keywordflow">return</span> dir &amp; 48;
<a name="l00393"></a>00393     }
<a name="l00394"></a><a class="code" href="class_print_line.html#a34ddbda7b07722da0e1b93001d549a4a">00394</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a34ddbda7b07722da0e1b93001d549a4a">isZMove</a>()
<a name="l00395"></a>00395     {
<a name="l00396"></a>00396         <span class="keywordflow">return</span> (dir &amp; 64);
<a name="l00397"></a>00397     }
<a name="l00398"></a><a class="code" href="class_print_line.html#a303bf057849da5f62827cfdbc2ad6326">00398</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a303bf057849da5f62827cfdbc2ad6326">isEMove</a>()
<a name="l00399"></a>00399     {
<a name="l00400"></a>00400         <span class="keywordflow">return</span> (dir &amp; 128);
<a name="l00401"></a>00401     }
<a name="l00402"></a><a class="code" href="class_print_line.html#a4833a7f801c417b392ecb5504d0a1cef">00402</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a4833a7f801c417b392ecb5504d0a1cef">isEOnlyMove</a>()
<a name="l00403"></a>00403     {
<a name="l00404"></a>00404         <span class="keywordflow">return</span> (dir &amp; 240)==128;
<a name="l00405"></a>00405     }
<a name="l00406"></a><a class="code" href="class_print_line.html#a589c1fda795565f72c8872cb8a1a389b">00406</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a589c1fda795565f72c8872cb8a1a389b">isNoMove</a>()
<a name="l00407"></a>00407     {
<a name="l00408"></a>00408         <span class="keywordflow">return</span> (dir &amp; 240)==0;
<a name="l00409"></a>00409     }
<a name="l00410"></a><a class="code" href="class_print_line.html#a04d6b0f87d5f38101802d9ebf704e1fd">00410</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a04d6b0f87d5f38101802d9ebf704e1fd">isXYZMove</a>()
<a name="l00411"></a>00411     {
<a name="l00412"></a>00412         <span class="keywordflow">return</span> dir &amp; 112;
<a name="l00413"></a>00413     }
<a name="l00414"></a><a class="code" href="class_print_line.html#a0d92e184b7728d79f2d932db5bde6c8d">00414</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0d92e184b7728d79f2d932db5bde6c8d">isMoveOfAxis</a>(uint8_t axis)
<a name="l00415"></a>00415     {
<a name="l00416"></a>00416         <span class="keywordflow">return</span> (dir &amp; (16&lt;&lt;axis));
<a name="l00417"></a>00417     }
<a name="l00418"></a><a class="code" href="class_print_line.html#a6cc01d8dcc37c4fa8fdaa67b3cbaa9aa">00418</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a6cc01d8dcc37c4fa8fdaa67b3cbaa9aa">setMoveOfAxis</a>(uint8_t axis)
<a name="l00419"></a>00419     {
<a name="l00420"></a>00420         dir |= 16&lt;&lt;axis;
<a name="l00421"></a>00421     }
<a name="l00422"></a><a class="code" href="class_print_line.html#a58c08ce30a6b0df067300649e37fdbba">00422</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a58c08ce30a6b0df067300649e37fdbba">setPositiveDirectionForAxis</a>(uint8_t axis)
<a name="l00423"></a>00423     {
<a name="l00424"></a>00424         dir |= 1&lt;&lt;axis;
<a name="l00425"></a>00425     }
<a name="l00426"></a><a class="code" href="class_print_line.html#ab108ad89fc717b8579f35975468f33c7">00426</a>     <span class="keyword">inline</span> <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ab108ad89fc717b8579f35975468f33c7">resetPathPlanner</a>()
<a name="l00427"></a>00427     {
<a name="l00428"></a>00428         <a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef" title="Number of lines cached 0 = nothing to do.">linesCount</a> = 0;
<a name="l00429"></a>00429         <a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a> = <a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a>;
<a name="l00430"></a>00430     }
<a name="l00431"></a><a class="code" href="class_print_line.html#a02b156fb6ea70b1a333ffad181931916">00431</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a02b156fb6ea70b1a333ffad181931916">updateAdvanceSteps</a>(<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> v,uint8_t max_loops,<span class="keywordtype">bool</span> accelerate)
<a name="l00432"></a>00432     {
<a name="l00433"></a>00433 <span class="preprocessor">#ifdef USE_ADVANCE</span>
<a name="l00434"></a>00434 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(!<a class="code" href="class_printer.html#aba3ee90af08480efce19332e6820b7bc">Printer::isAdvanceActivated</a>()) <span class="keywordflow">return</span>;
<a name="l00435"></a>00435 <span class="preprocessor">#ifdef ENABLE_QUADRATIC_ADVANCE</span>
<a name="l00436"></a>00436 <span class="preprocessor"></span>        <span class="keywordtype">long</span> advanceTarget = Printer::advanceExecuted;
<a name="l00437"></a>00437         <span class="keywordflow">if</span>(accelerate)
<a name="l00438"></a>00438         {
<a name="l00439"></a>00439             <span class="keywordflow">for</span>(uint8_t loop = 0; loop&lt;max_loops; loop++) advanceTarget += advanceRate;
<a name="l00440"></a>00440             <span class="keywordflow">if</span>(advanceTarget&gt;advanceFull)
<a name="l00441"></a>00441                 advanceTarget = advanceFull;
<a name="l00442"></a>00442         }
<a name="l00443"></a>00443         <span class="keywordflow">else</span>
<a name="l00444"></a>00444         {
<a name="l00445"></a>00445             <span class="keywordflow">for</span>(uint8_t loop = 0; loop&lt;max_loops; loop++) advanceTarget -= advanceRate;
<a name="l00446"></a>00446             <span class="keywordflow">if</span>(advanceTarget&lt;advanceEnd)
<a name="l00447"></a>00447                 advanceTarget = advanceEnd;
<a name="l00448"></a>00448         }
<a name="l00449"></a>00449         <span class="keywordtype">long</span> h = <a class="code" href="class_h_a_l.html#aed81729e739297a283a88c4313c4d247">HAL::mulu16xu16to32</a>(v,advanceL);
<a name="l00450"></a>00450         <span class="keywordtype">int</span> tred = ((advanceTarget + h) &gt;&gt; 16);
<a name="l00451"></a>00451         <a class="code" href="class_h_a_l.html#a9d22df0fcf68ff5b98b830b2292515e7">HAL::forbidInterrupts</a>();
<a name="l00452"></a>00452         Printer::extruderStepsNeeded += tred-Printer::advanceStepsSet;
<a name="l00453"></a>00453         <span class="keywordflow">if</span>(tred&gt;0 &amp;&amp; Printer::advanceStepsSet&lt;=0)
<a name="l00454"></a>00454             Printer::extruderStepsNeeded += <a class="code" href="class_extruder.html#a9af7fb6cd3428b4cb073eb8f1457ba6a">Extruder::current</a>-&gt;advanceBacklash;
<a name="l00455"></a>00455         <span class="keywordflow">else</span> <span class="keywordflow">if</span>(tred&lt;0 &amp;&amp; Printer::advanceStepsSet&gt;=0)
<a name="l00456"></a>00456             Printer::extruderStepsNeeded -= <a class="code" href="class_extruder.html#a9af7fb6cd3428b4cb073eb8f1457ba6a">Extruder::current</a>-&gt;advanceBacklash;
<a name="l00457"></a>00457         Printer::advanceStepsSet = tred;
<a name="l00458"></a>00458         <a class="code" href="class_h_a_l.html#af342bda39004b757cd9656dd9deb90df">HAL::allowInterrupts</a>();
<a name="l00459"></a>00459         Printer::advanceExecuted = advanceTarget;
<a name="l00460"></a>00460 <span class="preprocessor">#else</span>
<a name="l00461"></a>00461 <span class="preprocessor"></span>        <span class="keywordtype">int</span> tred = <a class="code" href="class_h_a_l.html#a5865166dfdd8a9ff9bd57f7d0c970856">HAL::mulu6xu16shift16</a>(v,advanceL);
<a name="l00462"></a>00462         <a class="code" href="class_h_a_l.html#a9d22df0fcf68ff5b98b830b2292515e7">HAL::forbidInterrupts</a>();
<a name="l00463"></a>00463         Printer::extruderStepsNeeded += tred - Printer::advanceStepsSet;
<a name="l00464"></a>00464         <span class="keywordflow">if</span>(tred&gt;0 &amp;&amp; Printer::advanceStepsSet&lt;=0)
<a name="l00465"></a>00465             Printer::extruderStepsNeeded += (<a class="code" href="class_extruder.html#a9af7fb6cd3428b4cb073eb8f1457ba6a">Extruder::current</a>-&gt;advanceBacklash &lt;&lt; 1);
<a name="l00466"></a>00466         <span class="keywordflow">else</span> <span class="keywordflow">if</span>(tred&lt;0 &amp;&amp; Printer::advanceStepsSet&gt;=0)
<a name="l00467"></a>00467             Printer::extruderStepsNeeded -= (<a class="code" href="class_extruder.html#a9af7fb6cd3428b4cb073eb8f1457ba6a">Extruder::current</a>-&gt;advanceBacklash &lt;&lt; 1);
<a name="l00468"></a>00468         Printer::advanceStepsSet = tred;
<a name="l00469"></a>00469         <a class="code" href="class_h_a_l.html#af342bda39004b757cd9656dd9deb90df">HAL::allowInterrupts</a>();
<a name="l00470"></a>00470 <span class="preprocessor">#endif</span>
<a name="l00471"></a>00471 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00472"></a>00472 <span class="preprocessor"></span>    }
<a name="l00473"></a><a class="code" href="class_print_line.html#a185d05cba96f5d94aee41c3d06c9c1cb">00473</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a185d05cba96f5d94aee41c3d06c9c1cb">moveDecelerating</a>()
<a name="l00474"></a>00474     {
<a name="l00475"></a>00475         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a5a87d2c42cc21fa0022be9e1450a6877" title="Remaining steps, until move is finished.">stepsRemaining</a> &lt;= <a class="code" href="class_print_line.html#a9ff32dda312a8ba553474117042721d4" title="How much steps does it take, to reach the end speed.">decelSteps</a>)
<a name="l00476"></a>00476         {
<a name="l00477"></a>00477             <span class="keywordflow">if</span> (!(<a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> &amp; <a class="code" href="motion_8h.html#ae80288e7929d2dd9a7a4aedcbbb53dbc">FLAG_DECELERATING</a>))
<a name="l00478"></a>00478             {
<a name="l00479"></a>00479                 <a class="code" href="class_printer.html#a61d9ef65d75b66821896182b133b31de" title="used for acceleration/deceleration timing">Printer::timer</a> = 0;
<a name="l00480"></a>00480                 <a class="code" href="class_print_line.html#a27ac1730f3c9b0d5935ac0c406f7b9f3">flags</a> |= <a class="code" href="motion_8h.html#ae80288e7929d2dd9a7a4aedcbbb53dbc">FLAG_DECELERATING</a>;
<a name="l00481"></a>00481             }
<a name="l00482"></a>00482             <span class="keywordflow">return</span> <span class="keyword">true</span>;
<a name="l00483"></a>00483         }
<a name="l00484"></a>00484         <span class="keywordflow">else</span> <span class="keywordflow">return</span> <span class="keyword">false</span>;
<a name="l00485"></a>00485     }
<a name="l00486"></a><a class="code" href="class_print_line.html#a0ff391b4272c58fb480c2d7ccb5cae34">00486</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a0ff391b4272c58fb480c2d7ccb5cae34">moveAccelerating</a>()
<a name="l00487"></a>00487     {
<a name="l00488"></a>00488         <span class="keywordflow">return</span> <a class="code" href="class_printer.html#a648a9d8aa6e009ed42e31edcf5b2944e" title="Step number in current move.">Printer::stepNumber</a> &lt;= <a class="code" href="class_print_line.html#afd69a1548f5674700c6ba5fd6a55914c" title="How much steps does it take, to reach the plateau.">accelSteps</a>;
<a name="l00489"></a>00489     }
<a name="l00490"></a><a class="code" href="class_print_line.html#a1506bdf7601a311bb8a65369a470595f">00490</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a1506bdf7601a311bb8a65369a470595f">isFullstepping</a>()
<a name="l00491"></a>00491     {
<a name="l00492"></a>00492         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#aa5bb967d7e0b7e9ec796f65835ee9d6e" title="4 = disabled, 1 = halfstep, 2 = fulstep">halfStep</a> == 4;
<a name="l00493"></a>00493     }
<a name="l00494"></a><a class="code" href="class_print_line.html#ad91731df82d6fff7e14a54e1799d0240">00494</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ad91731df82d6fff7e14a54e1799d0240">startXStep</a>()
<a name="l00495"></a>00495     {
<a name="l00496"></a>00496         <a class="code" href="_repetier_8h.html#a3c648c7bfb447c81831559d893ccc8b7">ANALYZER_ON</a>(<a class="code" href="_repetier_8h.html#ad0a2eedb5774ac5a46b3c4275126b815">ANALYZER_CH6</a>);
<a name="l00497"></a>00497 <span class="preprocessor">#if DRIVE_SYSTEM==0 || !defined(XY_GANTRY)</span>
<a name="l00498"></a>00498 <span class="preprocessor"></span>        <a class="code" href="_repetier_8h.html#a3c648c7bfb447c81831559d893ccc8b7">ANALYZER_ON</a>(<a class="code" href="_repetier_8h.html#af2973fcf8425b4a4c4752a52c6713c8f">ANALYZER_CH2</a>);
<a name="l00499"></a>00499         <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="pins_8h.html#a3018c6ebc4818a40ca658b5bbf2d044f">X_STEP_PIN</a>,HIGH);
<a name="l00500"></a>00500 <span class="preprocessor">#if FEATURE_TWO_XSTEPPER</span>
<a name="l00501"></a>00501 <span class="preprocessor"></span>        <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="_configuration_8h.html#a3c065952d4985697e1b1095e8236a0b9">X2_STEP_PIN</a>,HIGH);
<a name="l00502"></a>00502 <span class="preprocessor">#endif</span>
<a name="l00503"></a>00503 <span class="preprocessor"></span><span class="preprocessor">#else</span>
<a name="l00504"></a>00504 <span class="preprocessor"></span><span class="preprocessor">#if DRIVE_SYSTEM==1</span>
<a name="l00505"></a>00505 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">isXPositiveMove</a>())
<a name="l00506"></a>00506         {
<a name="l00507"></a>00507             Printer::motorX++;
<a name="l00508"></a>00508             Printer::motorY++;
<a name="l00509"></a>00509         }
<a name="l00510"></a>00510         <span class="keywordflow">else</span>
<a name="l00511"></a>00511         {
<a name="l00512"></a>00512             Printer::motorX--;
<a name="l00513"></a>00513             Printer::motorY--;
<a name="l00514"></a>00514         }
<a name="l00515"></a>00515 <span class="preprocessor">#endif</span>
<a name="l00516"></a>00516 <span class="preprocessor"></span><span class="preprocessor">#if DRIVE_SYSTEM==2</span>
<a name="l00517"></a>00517 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#ae48ce1b538c9a4d72bab89516f1ea44b">isXPositiveMove</a>())
<a name="l00518"></a>00518         {
<a name="l00519"></a>00519             Printer::motorX++;
<a name="l00520"></a>00520             Printer::motorY--;
<a name="l00521"></a>00521         }
<a name="l00522"></a>00522         <span class="keywordflow">else</span>
<a name="l00523"></a>00523         {
<a name="l00524"></a>00524             Printer::motorX--;
<a name="l00525"></a>00525             Printer::motorY++;
<a name="l00526"></a>00526         }
<a name="l00527"></a>00527 <span class="preprocessor">#endif</span>
<a name="l00528"></a>00528 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00529"></a>00529 <span class="preprocessor"></span><span class="preprocessor">#ifdef DEBUG_STEPCOUNT</span>
<a name="l00530"></a>00530 <span class="preprocessor"></span>        totalStepsRemaining--;
<a name="l00531"></a>00531 <span class="preprocessor">#endif</span>
<a name="l00532"></a>00532 <span class="preprocessor"></span>
<a name="l00533"></a>00533     }
<a name="l00534"></a><a class="code" href="class_print_line.html#a977d33618d886abff53e1e8bedbe7537">00534</a>     <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#a977d33618d886abff53e1e8bedbe7537">startYStep</a>()
<a name="l00535"></a>00535     {
<a name="l00536"></a>00536         <a class="code" href="_repetier_8h.html#a3c648c7bfb447c81831559d893ccc8b7">ANALYZER_ON</a>(<a class="code" href="_repetier_8h.html#a62ce8e11506218f41528a9059d4ce83a">ANALYZER_CH7</a>);
<a name="l00537"></a>00537 <span class="preprocessor">#if DRIVE_SYSTEM==0 || !defined(XY_GANTRY)</span>
<a name="l00538"></a>00538 <span class="preprocessor"></span>        <a class="code" href="_repetier_8h.html#a3c648c7bfb447c81831559d893ccc8b7">ANALYZER_ON</a>(<a class="code" href="_repetier_8h.html#a82feee50d46677c33675d367b1a85af2">ANALYZER_CH3</a>);
<a name="l00539"></a>00539         <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="pins_8h.html#a9313863a817f571f7a89deeaf77662fb">Y_STEP_PIN</a>,HIGH);
<a name="l00540"></a>00540 <span class="preprocessor">#if FEATURE_TWO_YSTEPPER</span>
<a name="l00541"></a>00541 <span class="preprocessor"></span>        <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="_configuration_8h.html#aa0057d47f91277e928db606389336d78">Y2_STEP_PIN</a>,HIGH);
<a name="l00542"></a>00542 <span class="preprocessor">#endif</span>
<a name="l00543"></a>00543 <span class="preprocessor"></span><span class="preprocessor">#else</span>
<a name="l00544"></a>00544 <span class="preprocessor"></span><span class="preprocessor">#if DRIVE_SYSTEM==1</span>
<a name="l00545"></a>00545 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">isYPositiveMove</a>())
<a name="l00546"></a>00546         {
<a name="l00547"></a>00547             Printer::motorX++;
<a name="l00548"></a>00548             Printer::motorY--;
<a name="l00549"></a>00549         }
<a name="l00550"></a>00550         <span class="keywordflow">else</span>
<a name="l00551"></a>00551         {
<a name="l00552"></a>00552             Printer::motorX--;
<a name="l00553"></a>00553             Printer::motorY++;
<a name="l00554"></a>00554         }
<a name="l00555"></a>00555 <span class="preprocessor">#endif</span>
<a name="l00556"></a>00556 <span class="preprocessor"></span><span class="preprocessor">#if DRIVE_SYSTEM==2</span>
<a name="l00557"></a>00557 <span class="preprocessor"></span>        <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a01f9499bddb3765edbfa3ab02d7a4717">isYPositiveMove</a>())
<a name="l00558"></a>00558         {
<a name="l00559"></a>00559             Printer::motorX++;
<a name="l00560"></a>00560             Printer::motorY++;
<a name="l00561"></a>00561         }
<a name="l00562"></a>00562         <span class="keywordflow">else</span>
<a name="l00563"></a>00563         {
<a name="l00564"></a>00564             Printer::motorX--;
<a name="l00565"></a>00565             Printer::motorY--;
<a name="l00566"></a>00566         }
<a name="l00567"></a>00567 <span class="preprocessor">#endif</span>
<a name="l00568"></a>00568 <span class="preprocessor"></span><span class="preprocessor">#endif // XY_GANTRY</span>
<a name="l00569"></a>00569 <span class="preprocessor"></span><span class="preprocessor">#ifdef DEBUG_STEPCOUNT</span>
<a name="l00570"></a>00570 <span class="preprocessor"></span>        totalStepsRemaining--;
<a name="l00571"></a>00571 <span class="preprocessor">#endif</span>
<a name="l00572"></a>00572 <span class="preprocessor"></span>    }
<a name="l00573"></a><a class="code" href="class_print_line.html#a0dd7c3d82c092f0a9ae892557c4eacee">00573</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a0dd7c3d82c092f0a9ae892557c4eacee">startZStep</a>()
<a name="l00574"></a>00574     {
<a name="l00575"></a>00575         <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="pins_8h.html#a07eb0240238e8582d5a00fb67179d325">Z_STEP_PIN</a>,HIGH);
<a name="l00576"></a>00576 <span class="preprocessor">#if FEATURE_TWO_ZSTEPPER</span>
<a name="l00577"></a>00577 <span class="preprocessor"></span>        <a class="code" href="fastio_8h.html#a3d38c0667426652d3fa2eb62f23e1591" title="Write to a pin wrapper.">WRITE</a>(<a class="code" href="_configuration_8h.html#a74542a04437600f9bf1ac6f3dd5e8c0d">Z2_STEP_PIN</a>,HIGH);
<a name="l00578"></a>00578 <span class="preprocessor">#endif</span>
<a name="l00579"></a>00579 <span class="preprocessor"></span>    }
<a name="l00580"></a>00580     <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ad7634c34ecbb519f55ce563c68e34a35">updateStepsParameter</a>();
<a name="l00581"></a>00581     <span class="keyword">inline</span> <span class="keywordtype">float</span> <a class="code" href="class_print_line.html#a3b93b1bbc75d084e92b47bbc25211f33">safeSpeed</a>();
<a name="l00582"></a>00582     <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a1150dd94076ec18892b8d67c7d96984a">calculateMove</a>(<span class="keywordtype">float</span> axis_diff[],uint8_t pathOptimize);
<a name="l00583"></a>00583     <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a8805ff9aa252959d474ac0adec4388dc">logLine</a>();
<a name="l00584"></a><a class="code" href="class_print_line.html#a65d5a0b47b70aa42878c4ddd870d6778">00584</a>     <span class="keyword">inline</span> <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a65d5a0b47b70aa42878c4ddd870d6778">getWaitTicks</a>()
<a name="l00585"></a>00585     {
<a name="l00586"></a>00586         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a606788ac5a4df6a49dac455473a1bb73">timeInTicks</a>;
<a name="l00587"></a>00587     }
<a name="l00588"></a><a class="code" href="class_print_line.html#aaa5de19d9ddb2912455b5d71daadd184">00588</a>     <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#aaa5de19d9ddb2912455b5d71daadd184">setWaitTicks</a>(<span class="keywordtype">long</span> wait)
<a name="l00589"></a>00589     {
<a name="l00590"></a>00590         <a class="code" href="class_print_line.html#a606788ac5a4df6a49dac455473a1bb73">timeInTicks</a> = wait;
<a name="l00591"></a>00591     }
<a name="l00592"></a>00592 
<a name="l00593"></a><a class="code" href="class_print_line.html#ac0f744468b329f082ba63208368e5264">00593</a>     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">bool</span> <a class="code" href="class_print_line.html#ac0f744468b329f082ba63208368e5264">hasLines</a>()
<a name="l00594"></a>00594     {
<a name="l00595"></a>00595         <span class="keywordflow">return</span> <a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef" title="Number of lines cached 0 = nothing to do.">linesCount</a>;
<a name="l00596"></a>00596     }
<a name="l00597"></a><a class="code" href="class_print_line.html#a64ae91c7dc648d0b337d0f324276a4bf">00597</a>     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a64ae91c7dc648d0b337d0f324276a4bf">setCurrentLine</a>()
<a name="l00598"></a>00598     {
<a name="l00599"></a>00599         <a class="code" href="class_print_line.html#a272556ffc75dd36b17dba53b9e81de88" title="Current printing line.">cur</a> = &amp;<a class="code" href="class_print_line.html#a3fc3b5578c9735d1af55e62111fb9f03" title="Cache for print moves.">lines</a>[<a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a>];
<a name="l00600"></a>00600 <span class="preprocessor">#if CPU_ARCH==ARCH_ARM</span>
<a name="l00601"></a>00601 <span class="preprocessor"></span>        <a class="code" href="class_print_line.html#aef1b1ee43dd2cf1e9322f6c2c946c145">PrintLine::nlFlag</a> = <span class="keyword">true</span>;
<a name="l00602"></a>00602 <span class="preprocessor">#endif</span>
<a name="l00603"></a>00603 <span class="preprocessor"></span>    }
<a name="l00604"></a><a class="code" href="class_print_line.html#a3389daad6d842f71a2ce60e7cee9b59f">00604</a>     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a3389daad6d842f71a2ce60e7cee9b59f">removeCurrentLineForbidInterrupt</a>()
<a name="l00605"></a>00605     {
<a name="l00606"></a>00606         <a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a>++;
<a name="l00607"></a>00607         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a>&gt;=<a class="code" href="_configuration_8h.html#a814de552a068ff380ac7ec841e7b595b" title="Number of moves we can cache in advance.">MOVE_CACHE_SIZE</a>) <a class="code" href="class_print_line.html#acad7185c78a2f5cdae2ca5c2d33e0098" title="Position for executing line movement.">linesPos</a>=0;
<a name="l00608"></a>00608         <a class="code" href="class_print_line.html#a272556ffc75dd36b17dba53b9e81de88" title="Current printing line.">cur</a> = NULL;
<a name="l00609"></a>00609 <span class="preprocessor">#if CPU_ARCH==ARCH_ARM</span>
<a name="l00610"></a>00610 <span class="preprocessor"></span>        <a class="code" href="class_print_line.html#aef1b1ee43dd2cf1e9322f6c2c946c145">nlFlag</a> = <span class="keyword">false</span>;
<a name="l00611"></a>00611 <span class="preprocessor">#endif</span>
<a name="l00612"></a>00612 <span class="preprocessor"></span>        <a class="code" href="class_h_a_l.html#a9d22df0fcf68ff5b98b830b2292515e7">HAL::forbidInterrupts</a>();
<a name="l00613"></a>00613         --<a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef" title="Number of lines cached 0 = nothing to do.">linesCount</a>;
<a name="l00614"></a>00614     }
<a name="l00615"></a><a class="code" href="class_print_line.html#aaf39d3ac51c339076ef1629174482a40">00615</a>     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#aaf39d3ac51c339076ef1629174482a40">pushLine</a>()
<a name="l00616"></a>00616     {
<a name="l00617"></a>00617         <a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a>++;
<a name="l00618"></a>00618         <span class="keywordflow">if</span>(<a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a>&gt;=<a class="code" href="_configuration_8h.html#a814de552a068ff380ac7ec841e7b595b" title="Number of moves we can cache in advance.">MOVE_CACHE_SIZE</a>) <a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a> = 0;
<a name="l00619"></a>00619         <a class="code" href="_h_a_l_8h.html#a0f536b06f8e01ba1a6d1d60416b7e3f7">BEGIN_INTERRUPT_PROTECTED</a>
<a name="l00620"></a>00620         <a class="code" href="class_print_line.html#a01dcbe9b4aff4513724de52cc33c43ef" title="Number of lines cached 0 = nothing to do.">linesCount</a>++;
<a name="l00621"></a>00621         <a class="code" href="_h_a_l_8h.html#a1f77fa92e63e79db1d3b45fbefbd26d8">END_INTERRUPT_PROTECTED</a>
<a name="l00622"></a>00622     }
<a name="l00623"></a><a class="code" href="class_print_line.html#a9989870df088bf4b9a3928c8a2ded9dc">00623</a>     <span class="keyword">static</span> <a class="code" href="class_print_line.html">PrintLine</a> *<a class="code" href="class_print_line.html#a9989870df088bf4b9a3928c8a2ded9dc">getNextWriteLine</a>()
<a name="l00624"></a>00624     {
<a name="l00625"></a>00625         <span class="keywordflow">return</span> &amp;<a class="code" href="class_print_line.html#a3fc3b5578c9735d1af55e62111fb9f03" title="Cache for print moves.">lines</a>[<a class="code" href="class_print_line.html#a9b6dff2988e435415f372da23ed41ea1" title="Position where we write the next cached line move.">linesWritePos</a>];
<a name="l00626"></a>00626     }
<a name="l00627"></a>00627     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a4ac503fa04c929695e63fdb2944e1dd5">computeMaxJunctionSpeed</a>(<a class="code" href="class_print_line.html">PrintLine</a> *previous,<a class="code" href="class_print_line.html">PrintLine</a> *current);
<a name="l00628"></a>00628     <span class="keyword">static</span> <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#a28814f549b2b24f24dda3d9cabe87891">bresenhamStep</a>();
<a name="l00629"></a>00629     <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a25fdee8d93b7445b19b2531646ac2bd5">waitForXFreeLines</a>(uint8_t b=1);
<a name="l00630"></a>00630     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a68ee05349131a0547059e83b6759de44">forwardPlanner</a>(uint8_t p);
<a name="l00631"></a>00631     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a438c11584123ee62c9d8393a16c17108">backwardPlanner</a>(uint8_t p,uint8_t last);
<a name="l00632"></a>00632     <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ae0e4f0562f9d7c223b6024a619205b60">updateTrapezoids</a>();
<a name="l00633"></a>00633     <span class="keyword">static</span> uint8_t <a class="code" href="class_print_line.html#abc890f0c9b72c63cfd69ba8acebc93d8">insertWaitMovesIfNeeded</a>(uint8_t pathOptimize, uint8_t waitExtraLines);
<a name="l00634"></a>00634     <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a5d5b134b285f04c291d3da308fce3419">queueCartesianMove</a>(uint8_t check_endstops,uint8_t pathOptimize);
<a name="l00635"></a>00635     <span class="keyword">static</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#aec8285a6e133b08a1edaebdbc7efc48a">moveRelativeDistanceInSteps</a>(<span class="keywordtype">long</span> x,<span class="keywordtype">long</span> y,<span class="keywordtype">long</span> z,<span class="keywordtype">long</span> e,<span class="keywordtype">float</span> feedrate,<span class="keywordtype">bool</span> waitEnd,<span class="keywordtype">bool</span> check_endstop);
<a name="l00636"></a>00636 <span class="preprocessor">#if ARC_SUPPORT</span>
<a name="l00637"></a>00637 <span class="preprocessor"></span>    <span class="keyword">static</span> <span class="keywordtype">void</span> arc(<span class="keywordtype">float</span> *position, <span class="keywordtype">float</span> *target, <span class="keywordtype">float</span> *offset, <span class="keywordtype">float</span> radius, uint8_t isclockwise);
<a name="l00638"></a>00638 <span class="preprocessor">#endif</span>
<a name="l00639"></a><a class="code" href="class_print_line.html#a7d777929106a32402b16c98b9582e8b2">00639</a> <span class="preprocessor"></span>    <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#a7d777929106a32402b16c98b9582e8b2">previousPlannerIndex</a>(uint8_t &amp;p)
<a name="l00640"></a>00640     {
<a name="l00641"></a>00641         p = (p ? p-1 : <a class="code" href="_configuration_8h.html#a814de552a068ff380ac7ec841e7b595b" title="Number of moves we can cache in advance.">MOVE_CACHE_SIZE</a>-1);
<a name="l00642"></a>00642     }
<a name="l00643"></a><a class="code" href="class_print_line.html#ab6846ab1a62387be9fc0a53120660580">00643</a>     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> <a class="code" href="class_print_line.html#ab6846ab1a62387be9fc0a53120660580">nextPlannerIndex</a>(uint8_t&amp; p)
<a name="l00644"></a>00644     {
<a name="l00645"></a>00645         p = (p==<a class="code" href="_configuration_8h.html#a814de552a068ff380ac7ec841e7b595b" title="Number of moves we can cache in advance.">MOVE_CACHE_SIZE</a>-1?0:p+1);
<a name="l00646"></a>00646     }
<a name="l00647"></a>00647 <span class="preprocessor">#if NONLINEAR_SYSTEM</span>
<a name="l00648"></a>00648 <span class="preprocessor"></span>    <span class="keyword">static</span> <span class="keywordtype">void</span> queueDeltaMove(uint8_t check_endstops,uint8_t pathOptimize, uint8_t softEndstop);
<a name="l00649"></a>00649     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> queueEMove(<span class="keywordtype">long</span> e_diff,uint8_t check_endstops,uint8_t pathOptimize);
<a name="l00650"></a>00650     <span class="keyword">inline</span> uint16_t calculateDeltaSubSegments(uint8_t softEndstop);
<a name="l00651"></a>00651     <span class="keyword">static</span> <span class="keyword">inline</span> <span class="keywordtype">void</span> calculateDirectionAndDelta(<span class="keywordtype">long</span> difference[], uint8_t *dir, <span class="keywordtype">long</span> <a class="code" href="class_print_line.html#acddb9b941799c58b09b9ba557a550ba9" title="Steps we want to move.">delta</a>[]);
<a name="l00652"></a>00652     <span class="keyword">static</span> <span class="keyword">inline</span> uint8_t calculateDistance(<span class="keywordtype">float</span> axis_diff[], uint8_t dir, <span class="keywordtype">float</span> *<a class="code" href="class_print_line.html#a06f14a9abd47b91465f895d5259cdc1b">distance</a>);
<a name="l00653"></a>00653 <span class="preprocessor">#ifdef SOFTWARE_LEVELING &amp;&amp; DRIVE_SYSTEM==3</span>
<a name="l00654"></a>00654 <span class="preprocessor"></span>    <span class="keyword">static</span> <span class="keywordtype">void</span> calculatePlane(<span class="keywordtype">long</span> factors[], <span class="keywordtype">long</span> p1[], <span class="keywordtype">long</span> p2[], <span class="keywordtype">long</span> p3[]);
<a name="l00655"></a>00655     <span class="keyword">static</span> <span class="keywordtype">float</span> calcZOffset(<span class="keywordtype">long</span> factors[], <span class="keywordtype">long</span> pointX, <span class="keywordtype">long</span> pointY);
<a name="l00656"></a>00656 <span class="preprocessor">#endif</span>
<a name="l00657"></a>00657 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00658"></a>00658 <span class="preprocessor"></span>};
<a name="l00659"></a>00659 
<a name="l00660"></a>00660 
<a name="l00661"></a>00661 
<a name="l00662"></a>00662 <span class="preprocessor">#endif // MOTION_H_INCLUDED</span>
</pre></div></div><!-- contents -->
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Data Structures</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Friends</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Defines</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

  <div id="nav-path" class="navpath">
    <ul>
      <li class="navelem"><a class="el" href="motion_8h.html">motion.h</a>      </li>

    <li class="footer">Generated on Mon Dec 30 2013 18:53:02 for Repetier-Firmware by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.6.1 </li>
   </ul>
 </div>


</body>
</html>
